package com.video.video.service.impl;

import com.video.video.domain.DEdition;
import java.util.List;
import com.video.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.video.video.mapper.DEditionMapper;
import com.video.video.service.IDEditionService;

/**
 * APP版本控制Service业务层处理
 *
 * @author ruoyi
 * @date 2023-03-20
 */
@Service
public class DEditionServiceImpl implements IDEditionService
{
    @Autowired
    private DEditionMapper dEditionMapper;

    /**
     * 查询APP版本控制
     *
     * @param id APP版本控制主键
     * @return APP版本控制
     */
    @Override
    public DEdition selectDEditionById(Long id)
    {
        return dEditionMapper.selectDEditionById(id);
    }

    /**
     * 查询APP版本控制列表
     *
     * @param dEdition APP版本控制
     * @return APP版本控制
     */
    @Override
    public List<DEdition> selectDEditionList(DEdition dEdition)
    {
        return dEditionMapper.selectDEditionList(dEdition);
    }

    /**
     * 新增APP版本控制
     *
     * @param dEdition APP版本控制
     * @return 结果
     */
    @Override
    public int insertDEdition(DEdition dEdition)
    {
        dEdition.setCreateTime(DateUtils.getNowDate());
        return dEditionMapper.insertDEdition(dEdition);
    }

    /**
     * 修改APP版本控制
     *
     * @param dEdition APP版本控制
     * @return 结果
     */
    @Override
    public int updateDEdition(DEdition dEdition)
    {
        dEdition.setUpdateTime(DateUtils.getNowDate());
        return dEditionMapper.updateDEdition(dEdition);
    }

    /**
     * 批量删除APP版本控制
     *
     * @param ids 需要删除的APP版本控制主键
     * @return 结果
     */
    @Override
    public int deleteDEditionByIds(Long[] ids)
    {
        return dEditionMapper.deleteDEditionByIds(ids);
    }

    /**
     * 删除APP版本控制信息
     *
     * @param id APP版本控制主键
     * @return 结果
     */
    @Override
    public int deleteDEditionById(Long id)
    {
        return dEditionMapper.deleteDEditionById(id);
    }
}
